libmyc.so:mymath.o lib.o
	gcc -o $@ $^ -shared
%.o:%.c
	gcc -fPIC -c $<

.PHONY:clean
clean:
	rm -f *.so *.o mylibc *.tgz

.PHONY:output
output:
	mkdir mylibc
	mkdir -p mylibc/include
	mkdir -p mylibc/libc
	cp *.h mylibc/include
	cp *.so mylibc/libc
	tar czf mylibc.tgz mylibc

